Recent advancements in the field of image compression and decompression have led to the development of various codecs to encode and decode digital image data and videos. Typically, a codec, such as an encoder, may compress an image before transmitting the compressed image to a decoder for decompression. The encoder may utilize various lossless or lossy image or video compression techniques to generate the encoded bit stream that may be transmitted, over a communication channel, to the decoder. The encoder may further transmit an encoded header data in the encoded bit stream to the decoder. The encoded header data may include a number of encoded bits that corresponds to a number of decoding parameters, which are required for decompression of the compressed image by the decoder. However, in certain scenarios, where a plurality of different coding techniques are used for compression, the amount of header data may also increase to accommodate information of the plurality of different coding techniques. Thus, in such scenarios, it may be difficult to manage the number of bits in the encoded header data to efficiently store and transmit the encoded header data to the decoder. In scenarios where number of bits in the encoded header data and other encoded data of the compressed image is not managed efficiently, the compression and decompression processes may require high storage space and high memory access bandwidth, which may not be desirable. For example, the processes of storing and retrieving the compressed image, during the compression and decompression, may occur multiple times, and as a result, may consume a large amount of the memory storage and bandwidth. Such consumption of large amount of the memory storage and bandwidth may decrease the operating speed of the codecs during the various processes of the compression and decompression. Therefore, an improved implementation of the codecs may be desired.
Further limitations and disadvantages of conventional and traditional approaches will become apparent to one of skill in the art, through comparison of described systems with some aspects of the present disclosure, as set forth in the remainder of the present application and with reference to the drawings.